package com.ikas.ai.server.module.data.enums;

/**
 * @author hu.bowei@ikasinfo.com
 * @date 2023-5-6 17:06:58
 * @Description t_data_mete表type字段枚举
 */
public enum DataMeteTypeEnum {

    EXECUTE(0, "执行项"),
    RESPONSE(1, "响应项"),
    STEP(2, "步骤"),
    FLOW(3, "工况流程");

    private int code;
    private String name;

    private DataMeteTypeEnum(int code, String name) {
        this.code = code;
        this.name = name;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public static String getName(int code) {
        for (DataMeteTypeEnum value : DataMeteTypeEnum.values()) {
            if (value.code == code) {
                return value.name;
            }
        }
        return "----";
    }
}
